<?php
include "database_connection.php";
class AddWorksModel {
	private $db;
	
	function __construct() {
		$this->db = DatabaseConn::getInstance();
	}
	
	public function addArtwork($text1,$text2,$text3,$text4,$text5,$text6) {
		
		$t1 = mysql_real_escape_string($text1);
		$t2 = mysql_real_escape_string($text2);
		$t3 = mysql_real_escape_string($text3);
		$t4 = mysql_real_escape_string($text4);
		$t5 = mysql_real_escape_string($text5);
		$t6 = mysql_real_escape_string($text6);
		$sql = "INSERT INTO artwork (title, medium, dimensions,description,url,thumbnail)
				VALUES ('$t1','$t2','$t3','$t5','$t4','$t6')";
		if(mysql_query($sql)) {
				return "true";
		}
		return "false";
		
	
	}
	
	
}